package com.yangchao.ch05

/** java与groovy的区别 **/
class example_groovy {
    public static void main(String[] args) {
        def example = new example_groovy()
            Object ob = "aaa"
            println("Groovy:"+example.method(ob))  //Groovy is 1
        }

        int method(String arg) {
            return 1

        }

        int method(Object arg) {
            return 2
        }
    }